package publics.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

@Entity
@Table(name="proposer")
public class Proposer {//申请人征信情况
	
	private Integer id;//ID int not null,
	private Enterprise ent;
	private String entLoan;//企业借款（贷款）情况         varchar(100) not null,
	private String perLoan;//个人负债情况        varchar(100) not null,
	private String guarantee;//对外担保情况        varchar(100) not null,
	private String lawsuit;//法律诉讼或仲裁         varchar(100) not null,
	   //primary key (Pro_id)
	@Id
	@GeneratedValue
	@Column(name="Pro_id")
	public Integer getId() {
		return id;
	}
	@ManyToOne(fetch=FetchType.LAZY)
	@JoinColumn(name="Ent_id",nullable=false)
	public Enterprise getEnt() {
		return ent;
	}
	@Column(name="Pro_ent_loan")
	public String getEntLoan() {
		return entLoan;
	}
	@Column(name="Pro_per_loan")
	public String getPerLoan() {
		return perLoan;
	}
	@Column(name="Pro_guarantee")
	public String getGuarantee() {
		return guarantee;
	}
	@Column(name="Pro_lawsuit")
	public String getLawsuit() {
		return lawsuit;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public void setEnt(Enterprise ent) {
		this.ent = ent;
	}
	public void setEntLoan(String entLoan) {
		this.entLoan = entLoan;
	}
	public void setPerLoan(String perLoan) {
		this.perLoan = perLoan;
	}
	public void setGuarantee(String guarantee) {
		this.guarantee = guarantee;
	}
	public void setLawsuit(String lawsuit) {
		this.lawsuit = lawsuit;
	}
	/* (non-Javadoc)
	 * @see java.lang.Object#toString()
	 */
	@Override
	public String toString() {
		return "Proposer [ent=" + ent + ", entLoan=" + entLoan + ", guarantee="
				+ guarantee + ", id=" + id + ", lawsuit=" + lawsuit
				+ ", perLoan=" + perLoan + "]";
	}
	
	
	
}
